<?php
require_once("./DButil.php");


$sql="select courseId,courseName from t_course

";

if (query($sql)) {
    $result=query($sql);
}else{
    $result = [
        "msg" => "未存在",
        "code" => 404,
        "success" => false,
    ];
}

header("Content-Type:application/json;charset=utf-8");
echo json_encode($result);
?>